{__NOLAYOUT__}
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <title></title>
	{include file="public/script" /}
</head>
<body>
	<div class="sectionH sectionH2 mui-clearfix">
		<header class="mui-bar mui-bar-nav" style="">
			<a class="mui-icon mui-icon-left-nav  mui-pull-left" href="javascript:history.back(-1)" style="color: #727272;"></a>
			<h1 class="mui-title">发掘人脉</h1>
			<a class="mui-icon mui-pull-right right1" href="{:url('Connection/myConnection')}">我的人脉</a>
		</header>
	</div>
	<div class="kong1"></div>
	<div class="fajue_section1">
		<div class="container">
			<form action="" method="post">
				<div class="fajue_section1_1">
					<a href="{:url('Connection/Excavate')}">
						<div class="fa_big"><img src="__STATIC__/www/images/raw_1.png" class="img_big" /></div>
					</a>

					
					<div class="zbb">
						{volist name="list" id="l"}
						<div class="fa_small">
							<label for="">
								<img src="{$l.avatar|default='/static/default_avatar.png'}" class="img_small"/>
								<input type="checkbox" name="renmai" id="" value="{$l.id}" checked="" />
							</label>
						</div>
						{/volist}
					</div>
					
					
				</div>
				<input type="submit" value="" class="sub_sub"/>
			</form>
		</div>
	</div>
	<div class="fajue_section2">
		<div class="container">
			<!--<p class="p1"><a href="{:url('Connection/excavate')}" class="begin_cl">开始发掘</a></p>-->
			<p class="p2"><a href="javascript:follow();" class="begin_cll">一键关注</a></p>
			<p class="p3">点击开始发掘可继续发掘</p>
		</div>
	</div>
</body>

<script>
    function follow() {

        var ids= new Array();
        $("input[name='renmai']:checked").each(function(j,item){
            ids.push(item.value);
        });
        if(ids.length<=0)
        {
            mui.alert("没有可关注的会员！");
            return fasle;
        }
        ids=JSON.stringify(ids);

        var url="{:url('Connection/fastFollow')}";
        $.post(url,{ids:ids},function(data){
            var data=JSON.parse(data);
            if(data.result_code==='0000')
            {
                mui.alert("关注成功！","提示",function(){
                    window.location.reload();
                });

            }else{
                mui.alert(data.result_info,"提示",function(){
                    window.location.reload();
                });
            }
        })
    }


</script>
</html>